package com.example.client;

import com.example.business.SendFileBusiness;

public class ClientFrontend {
    private NetworkChannel networkChannel;
    private SendFileBusiness sendFileBusiness;

    public ClientFrontend() {
        // 初始化NetworkChannel，连接到服务器地址和端口
        this.networkChannel = new NetworkChannel("localhost", 8080); // 请确保服务器地址和端口正确
        this.sendFileBusiness = new SendFileBusiness(this.networkChannel);
    }

    public void start() {
        // 发送文件业务
        sendFileBusiness.execute();
    }

    public static void main(String[] args) {
        ClientFrontend clientFrontend = new ClientFrontend();
        clientFrontend.start();
    }
}
